package com.school.model;

import org.hibernate.SessionFactory;
import org.hibernate.cfg.AnnotationConfiguration;

public class SchoolSessionFactory {

	private static SessionFactory sessionFactory;

	private SchoolSessionFactory() {

	}

	static {
		sessionFactory = new AnnotationConfiguration().configure()
				.buildSessionFactory();
	}

	public static SessionFactory getInstance() {
		return sessionFactory;
	}

}
